Memory debugger

A memory debugger is a programming tool for finding memory leaks and buffer overflows. These are due to bugs related to the allocation and deallocation of dynamic memory. Programs written in languages that have garbage collection, such as managed code, might also need memory debuggers, e.g. for memory leaks due to "living" references in collections.

Contents

Overview

Memory debuggers work by monitoring memory access, allocations, and deallocation of memory. Many memory debuggers required to recompile applications with special dynamic memory allocation libraries whose APIs are mostly compatible with conventional dynamic memory allocation libraries to enable debugging (or use dynamic linking). Electric Fence is such a debugger which debugs memory allocation with malloc. Some memory debuggers (e.g:Valgrind) works by running the executable in a virtual machine like environment, monitoring memory access, allocation and deallocation so that no recompilation with special memory allocation libraries is required.

As abnormally high memory utilization can be a contributoring factor in software aging, memory debuggers can help programmers to avoid software anomalies that would exhaust the computer system memory, thus ensuring high reliability of the software even for long runtimes.

List of memory debugging tools

This is a list of tools useful for memory debugging. A profiler can be used in conjunction with a memory debugger.

See also

References

External links